package com.zhang.authoritycenter.common.mapper.auth;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zhang.authoritycenter.common.model.dao.auth.UserBaseDO;
import com.zhang.authoritycenter.common.model.dto.organization.OrganizationQueryReqDTO;
import com.zhang.authoritycenter.common.model.vo.organization.OrganizationUserQueryVO;
import com.zhang.infrastructure.api.model.authority.AuthByUserDTO;
import org.apache.ibatis.annotations.Param;

/**
 * <p>
 * 用户信息表 Mapper 接口
 * </p>
 *
 * @author KingHood
 * @since 2023-12-13
 */
public interface UserBaseMapper extends BaseMapper<UserBaseDO> {

    /**
     * 用户分页
     *
     * @param page 分页
     * @param in 筛选条件
     * @return 用户
     * @author zfj
     * @date 2023/12/18
     */
    Page<OrganizationUserQueryVO> queryPage(Page<Object> page,@Param("data") OrganizationQueryReqDTO in);

    /**
     * 获取账号的权限
     *
     * @param userId 账号id
     * @return 权限
     * @author zfj
     * @date 2023/12/22
     */
    AuthByUserDTO getAuth(@Param("userId") Long userId);
}
